/**
* The ClientPacket Class holds necessay information regarding client input to the server.
* Group: Y1
* @author Mason Kwiat
*/

//package network;
package lightspeed.Network;

import java.io.Serializable;

public class ClientPacket implements Serializable
{
	/**
	* The string message that the ClientPacket contains.
	*/
	public String message;
	/**
	* The string name of the ClientPacket instance.
	*/
	public String name;
	/**
	* Whenever the client hits left keys, thisboolean variable gets set to true. 
	*/
	public boolean leftDown; 
	/**
	* Whenever the client hits right keys, thisboolean variable gets set to true. 
	*/
	public boolean rightDown;
	/**
	* Whenever the client hits up keys, thisboolean variable gets set to true. 
	*/	
	public boolean upDown; 
		/**
	* Whenever the client hits down key, thisboolean variable gets set to true. 
	*/
	public boolean spaceDown;
	/**
	*	Constructor: creates an instance of the ClickPacket
	*	@param n holds the string which will be the name of the Clientpacket that is instantiated.
	*
	*	   
	*/
	public ClientPacket(String n)
	{
		message = "";
		name = n;
	}
	/**
	*	Sets the message of a ClinetPacket object. The string "s" aruguement specifies the message.
	*	@param s hold the string message which will be set once the method is called
	*	   
	*/
	public void setMessage(String s)
	{
		message = s;
	}
	/**
	*	Returns a string which hold the message of the ClientPackage object.
	*	@return  the message which the object hold. Will return an empty string if setMessage() was never called
	*/
	public String getMessage()
	{
		return message;
	}
}
